Skip to content

fix #539 - Prevent Monaco diagnostic hover clipping in the Dual Editor - #545

Merged
lornakelly merged 2 commits into
open-workflow-specification:mainfrom
fantonangeli:issue-539-bug-Monaco-diagnostic-hover-is-clipped-near-the-top-of-the-editor
Nov 18, 2026
Merged

lornakelly merged 2 commits into
open-workflow-specification:mainfrom
fantonangeli:issue-539-bug-Monaco-diagnostic-hover-is-clipped-near-the-top-of-the-editor

Conversation

@fantonangeli

@fantonangeli fantonangeli commented Nov 17, 2026 •

Copy link
Copy Markdown
Member

Closes #539

Description

Fix Monaco diagnostic hover tooltips being clipped near the boundaries of the Dual Editor.

Changes

  • Remove overflow: hidden from the Dual Editor root container.
  • Allow overflow from the Text Editor pane while preserving clipping in the Diagram Editor pane.
  • Allow overflow from the Vanilla Web Component container.

Alternative considered

I also evaluated using Monaco's fixedOverflowWidgets option , using:

const editor = monaco.editor.create(containerRef.current, {
  model,
  readOnly: isReadOnly,
  codeLens: !isReadOnly,
  automaticLayout: true,
  renderLineHighlight: "none",
  fixedOverflowWidgets: true,
  useShadowDOM: false,
  ...

Both approaches passed manual tests in this repository and Quarkus Flow as well.

I chose the CSS solution to preserve Monaco's default behaviour.

If the CSS approach proves insufficient in future integrations, the Monaco configuration remains a tested alternative worth reconsidering.

How to test

  1. Run the Vanilla Web Component example using pnpm start from examples/vanilla-web-component.
  2. Open a workflow containing validation errors.
  3. Scroll until a diagnostic is close to the top of the Text Editor.
  4. Hover over the diagnostic and verify that the tooltip is fully visible.
  5. Resize the Dual Editor panes to their minimum and maximum sizes.
  6. Repeat the test in the stacked layout, at different browser zoom levels, and while scrolling.
  7. Verify that Monaco autocomplete and context menus remain functional.
  8. Repeat in light and dark themes.

Manual testing

The CSS solution was manually compared with the Monaco configuration approach. Both passed the tested scenarios, including resizing, scrolling, hover positioning, autocomplete, context menus, and layout changes.

Preview

https://fantonangeli.github.io/open-workflow-specification-editor/issue-539/
Screenshot From 2026-11-17 12-20-10
Screenshot From 2026-11-16 18-33-37

Signed-off-by: Fabrizio Antonangeli <fabrizio.antonangeli@gmail.com>
Signed-off-by: Fabrizio Antonangeli <fabrizio.antonangeli@gmail.com>
Copilot AI balanced review requested due to automatic review settings November 17, 2026 13:26
@changeset-bot

changeset-bot Bot commented Nov 17, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 81a48b8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 0 packages

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@netlify

netlify Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

✅ Deploy Preview for openworkflow-editor ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 81a48b8
🔍 Latest deploy log https://app.netlify.com/projects/openworkflow-editor/deploys/6afc55f24a1acc4f0a0e2143
😎 Deploy Preview https://deploy-preview-545--openworkflow-editor.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@fantonangeli fantonangeli added the bug Something isn't working label Nov 17, 2026

@lornakelly lornakelly left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@fantonangeli

Copy link
Copy Markdown
Member Author

@lornakelly can you please merge this PR?

@lornakelly
lornakelly merged commit cabf579 into open-workflow-specification:main Nov 18, 2026
13 checks passed
@fantonangeli
fantonangeli deleted the issue-539-bug-Monaco-diagnostic-hover-is-clipped-near-the-top-of-the-editor branch November 18, 2026 15:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: Monaco diagnostic hover is clipped near the top of the editor

4 participants